<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateBloodGlucoseContrastTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('tn_blood_glucose_contrast', function (Blueprint $table) {
            $table->increments('id');
            $table->string('account',32)->comment('用户account');
            $table->unsignedTinyInteger('type')->comment("比值类型：1餐前 2餐后 3睡前 4凌晨");
            $table->float('max_value',4,2)->comment('比较值大');
            $table->float('min_value',4,2)->comment('比较值小');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('tn_blood_glucose_contrast');
    }
}
